mport pandas as pd
list=[[110,120,105],[95,110,108],[98,80,100],[112,106,97]]
index=['王蒙','李珊','赵胜','刘文']
columns=['语文','数学','英语']
df=pd.DataFrame(list,index,columns)
df1=df.rename({'英语':'政治'},axis='columns')
df1['政治']=[11,22,33,44]
print('原始数据:\n',df)
print('修改“英语”列为“体育”列后的数据：\n',df1)

df2=df.rename({'王蒙':'张如玉'})
print('修改“王蒙”列为“张如玉”后的数据：\n',df2)

df.index=['a','b','c','d']
df.columns=['1','2','3',]
print('修改行标签和列标签：\n',df)